package com.yu1996.gulimall.product.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.yu1996.common.utils.PageUtils;
import com.yu1996.gulimall.product.entity.CategoryEntity;

import com.yu1996.gulimall.product.vo.Catelog2Vo;
import java.util.List;
import java.util.Map;

/**
 * 商品三级分类
 *
 * @author yu
 * @email 1798121567@qq.com
 * @date 2021-08-04 17:31:00
 */
public interface CategoryService extends IService<CategoryEntity> {

  PageUtils queryPage(Map<String, Object> params);

  List<CategoryEntity> listForTree();

  Long[] findCatelogPath(Long catelogId);

  /** 级联修改 */
  void updateCascade(CategoryEntity category);

  /**
   * 查询分类一级标题返回
   *
   * @return
   */
  List<CategoryEntity> getLever1Categorys();

  /**
   * 查询出三级分类数据并封装到Vo中返回
   *
   * @return
   */
  Map<String, List<Catelog2Vo>> getCatelogJson();
}
